package com.qf.studentmanager.model;

import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;

public class Exam {
    private Integer eid;
    private String examName;
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date examDate;
    private String examType;
    private Integer gid;
    private Integer cid;
    private Integer crid;
    private  String remark;

    private Grade grade;
    private  Clazz clazz ;
    private  Course course;

    public Exam() {
    }

    public Exam(Integer eid, String examName, Date examDate, String examType, Integer gid, Integer cid, Integer crid, String remark, Grade grade, Clazz clazz, Course course) {
        this.eid = eid;
        this.examName = examName;
        this.examDate = examDate;
        this.examType = examType;
        this.gid = gid;
        this.cid = cid;
        this.crid = crid;
        this.remark = remark;
        this.grade = grade;
        this.clazz = clazz;
        this.course = course;
    }

    public Exam(String examName, Date examDate, String examType, Integer gid, Integer cid, Integer crid, String remark, Grade grade, Clazz clazz, Course course) {
        this.examName = examName;
        this.examDate = examDate;
        this.examType = examType;
        this.gid = gid;
        this.cid = cid;
        this.crid = crid;
        this.remark = remark;
        this.grade = grade;
        this.clazz = clazz;
        this.course = course;
    }

    public Exam(String examName, Date examDate, String examType, Integer gid, Integer cid, Integer crid, String remark) {
        this.examName = examName;
        this.examDate = examDate;
        this.examType = examType;
        this.gid = gid;
        this.cid = cid;
        this.crid = crid;
        this.remark = remark;
    }

    public Integer getEid() {
        return eid;
    }

    public void setEid(Integer eid) {
        this.eid = eid;
    }

    public String getExamName() {
        return examName;
    }

    public void setExamName(String examName) {
        this.examName = examName;
    }

    public Date getExamDate() {
        return examDate;
    }

    public void setExamDate(Date examDate) {
        this.examDate = examDate;
    }

    public String getExamType() {
        return examType;
    }

    public void setExamType(String examType) {
        this.examType = examType;
    }

    public Integer getGid() {
        return gid;
    }

    public void setGid(Integer gid) {
        this.gid = gid;
    }

    public Integer getCid() {
        return cid;
    }

    public void setCid(Integer cid) {
        this.cid = cid;
    }

    public Integer getCrid() {
        return crid;
    }

    public void setCrid(Integer crid) {
        this.crid = crid;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Grade getGrade() {
        return grade;
    }

    public void setGrade(Grade grade) {
        this.grade = grade;
    }

    public Clazz getClazz() {
        return clazz;
    }

    public void setClazz(Clazz clazz) {
        this.clazz = clazz;
    }

    public Course getCourse() {
        return course;
    }

    public void setCourse(Course course) {
        this.course = course;
    }

    @Override
    public String toString() {
        return "Exam{" +
                "eid=" + eid +
                ", examName='" + examName + '\'' +
                ", examDate=" + examDate +
                ", examType='" + examType + '\'' +
                ", gid=" + gid +
                ", cid=" + cid +
                ", crid=" + crid +
                ", remark='" + remark + '\'' +
                ", grade=" + grade +
                ", clazz=" + clazz +
                ", course=" + course +
                '}';
    }
}
